import type {App} from 'vue'
import { createPinia} from 'pinia'
import type {Pinia} from "pinia";
import persistedstate from 'pinia-plugin-persistedstate'

const store:Pinia = createPinia()
store.use(persistedstate)

//全局注册 store
export const setupStore = (app:App<Element>) =>{
    app.use(store)
}
export * from "./modules/user.ts"
export * from "./modules/permission.ts"
export  { store }